home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
System Booster
/
System Booster.iso
/
Directorytools
/
BrowserII V3.09
/
Install-BrowserII
< prev
next >
Wrap
Text File
|
1996-09-26
|
11KB
|
605 lines
; BrowserII Installation Script
;=============================================================================
(set @default-dest (expandpath "SYS:Utilities"))
(complete 0)
(set #NeedV37
(cat
"BrowserII requires AmigaOS 2.0 or higher."
)
)
(set #introduction
(cat
"Your are about to install BrowserII and related files into your system.\n"
"Some additionnal commands, ARexx and shell scripts are given to make your life easier with BrowserII.\n"
"You should install them at least as a tutorial. They may teach you a lot about BrowserII's phylosophy."
)
)
(set #AskBrowserDest
(cat
"Please select a place for \"BrowserII\". A drawer called \"BrowserII\" will be created here."
)
)
(set #WhereParMLibPrompt
(cat
"Where do you want to install parm.library ?\n\n"
"This library may be copied to the BrowserII's directory if you do not use any other tool that requires it. "
"There's actually only two: ParM and WBRun (given with this package).\n"
"If you use WBRun only in the context of BrowserII (in BrowserII.menu), "
"parm.library can be left in BrowserII's directory.\n"
"If an old parm.library is found in your LIBS:, it will be deleted."
)
)
(set #WBStartupPrompt
(cat
"Boot options..."
)
)
(set #StartBrowser
(cat
"Start BrowserII"
)
)
(set #StartIconified
(cat
"Start in iconified state"
)
)
(set #WhichCommandsPrompt
(cat
"Select shell commands to install..."
)
)
(set #AskCommandsDest
(cat
"Please select directory where to copy selected shell commands."
)
)
(set #WhichARexxPrompt
(cat
"Select ARexx scripts to install..."
)
)
(set #AskARexxDest
(cat
"Please select directory where to copy selected ARexx scripts."
)
)
(set #WhichScriptPrompt
(cat
"Select shell scripts to install..."
)
)
(set #AskScriptDest
(cat
"Please select directory where to copy selected shell scripts."
)
)
(set #MenuMoved
(cat
"Your file \"S:BrowserII.menu\" has been moved to \"%s\" where BrowserII will now read it.\n"
"Any way, you'll have to perform some small changes to it before running BrowserII version 3.\n"
"Refer to the documentation for more information."
)
)
;=============================================================================
(if (= @language "français")
(
(set #NeedV37
(cat
"BrowserII nécessite l'AmigaOS version 2.0 ou supérieure."
)
)
(set #introduction
(cat
"Vous êtes sur le point d'installer BrowserII et ses fichiers dans votre système.\n"
"Quelques commandes shell et scripts supplémentaires sont fournis afin de réaliser des tâches élémentaires.\n"
"Il est recommandé de les installer au moins dans un but de consultation afin de mieux comprendre les possibilités de BrowserII."
)
)
(set #AskBrowserDest
(cat
"Choisissez un endroit pour \"BrowserII\". Un répertoire nommé \"BrowserII\" y sera créé."
)
)
(set #AskCommandsDest
(cat
"Choisissez un répertoire pour les commandes shell."
)
)
(set #AskARexxDest
(cat
"Choisissez un répertoire pour les scripts ARexx."
)
)
(set #AskScriptDest
(cat
"Choisissez un répertoire pour les scripts shell."
)
)
(set #MenuMoved
(cat
"Votre fichier \"S:BrowserII.menu\" a été copié dans \"%s\" ou BrowserII le lira maintenant.\n"
"De plus, vous devez y faire quelques modifications mineures avant d'utiliser BrowserII version 3.\n"
"Référez vous à la documentation pour plus d'informations."
)
)
))
;=============================================================================
;(if (= @language "deutsch")
;(
;))
;=============================================================================
;=============================================================================
(set OSVersion (/ (getversion) 65536))
(if (< OSVersion 37)
(abort #NeedV37)
)
(message #introduction)
(set @default-dest
(askdir
(prompt #AskBrowserDest)
(help @askdir-help)
(default @default-dest)
)
)
(set WhereParMLib
(askchoice
(prompt #WhereParMLibPrompt)
(choices
@default-dest
"LIBS:"
)
(help @askchoice-help)
)
)
(set WBStartup
(askoptions
(prompt #WBStartupPrompt)
(choices
#StartBrowser
#StartIconified
)
(help @askoptions-help)
)
)
(set WhichCommands
(askoptions
(prompt #WhichCommandsPrompt)
(choices
"AddIcon"
"BaseName"
"BD"
"For"
"MakeLink"
"TackOn"
"VolName"
"WBInfo"
"WBRun"
)
(help @askoptions-help)
)
)
(if (<> WhichCommands 0)
(set CommandsDir
(askdir
(prompt #AskCommandsDest)
(help @askdir-help)
(default "C:")
)
)
)
(set WhichARexx
(askoptions
(prompt #WhichARexxPrompt)
(choices
"DeliPlay.rexx"
"View.adpro"
)
(help @askoptions-help)
)
)
(if (<> WhichARexx 0)
(set ARexxDir
(askdir
(prompt #AskARexxDest)
(help @askdir-help)
(default "REXX:")
)
)
)
(set WhichScript
(askoptions
(prompt #WhichScriptPrompt)
(choices
"AssignVol"
"Extract"
"LhArcDir"
"LhArcVol"
"PPDocToCed"
)
(help @askoptions-help)
)
)
(if (<> WhichScript 0)
(set ScriptDir
(askdir
(prompt #AskScriptDest)
(help @askdir-help)
(default "S:")
)
)
)
;=======================================================
;============== Install starts now! ====================
;=======================================================
(set DestDir (tackon @default-dest "BrowserII"))
(set BrowserIIDirExists (exists DestDir (noreq)))
(if (= BrowserIIDirExists 1)
(
(rename (tackon @default-dest "BrowserII") (tackon @default-dest "BrowserII.bak"))
(rename (tackon @default-dest "BrowserII.info") (tackon @default-dest "BrowserII.bak.info"))
(set BrowserIIDirExists 0) ; tells dir 'BrowserII' does not exists
))
(if (= BrowserIIDirExists 0)
(makedir
DestDir
(infos)
)
)
(copyfiles
(help @copyfiles-help)
(source "BrowserII")
(dest DestDir)
(infos)
)
(if (= WhereParMLib 1)
(
(copylib
(help @copylib-help)
(source "parm.library")
(dest "LIBS:")
)
)
(
(copylib
(help @copylib-help)
(source "parm.library")
(dest DestDir)
)
(delete "libs:parm.library")
))
(if (bitand WBStartup 1)
(
(copyfiles
(help @copyfiles-help)
(source "BrowserII_p.inf")
(newname "BrowserII.info")
(dest "SYS:WBStartup")
)
(tooltype
(dest (tackon "SYS:WBStartup" "BrowserII"))
(setdefaulttool (tackon DestDir "BrowserII"))
(noposition)
)
(if (bitand WBStartup 2)
(tooltype
(dest (tackon "SYS:WBStartup" "BrowserII"))
(settooltype "CX_POPUP=NO")
)
)
))
(copylib
(help @copylib-help)
(source "whatis.library")
(dest "LIBS:")
)
(if (NOT (exists "S:FileTypes" (noreq)))
(copyfiles
(help @copyfiles-help)
(source "S/FileTypes")
(dest "S:")
)
)
(if (<> WhichARexx 0)
(copylib
(help @copylib-help)
(source "libs/RexxDosSupport.library")
(dest "LIBS:")
)
)
(if (<> @language "english")
(
(makedir
(tackon DestDir "Catalogs")
)
(set CatalogPath (tackon "Catalogs" @language))
(copyfiles
(help @copyfiles-help)
(source CatalogPath)
(dest (tackon DestDir CatalogPath))
(all)
)
))
(copyfiles
(help @copyfiles-help)
(source "ReadMe")
(dest DestDir)
(infos)
)
;============ Docs ============
(if (NOT (exists (tackon DestDir "Help") (noreq)))
(makedir
(tackon DestDir "Help")
(infos)
)
)
(if (NOT (exists (tackon DestDir "Help/english") (noreq)))
(makedir
(tackon DestDir "Help/english")
(infos)
)
)
(foreach "Help/english" "~(#?_v40)"
(copyfiles
(help @copyfiles-help)
(source (tackon "Help/english" @each-name))
(dest (tackon DestDir "Help/english"))
(infos)
)
)
(set agvernum (/ (getversion "libs:amigaguide.library") 65536))
(if (>= agvernum 40)
(copyfiles
(help @copyfiles-help)
(source "Help/english/BrowserII.guide")
(dest (tackon DestDir "Help/english"))
(newname "BrowserII.guide")
)
)
(if (< OSVersion 39)
;have to convert the V40 guide to V39 compatible format.
)
;============ Icons ===========
(if (NOT (exists (tackon DestDir "Icons") (noreq)))
(makedir
(tackon DestDir "Icons")
(infos)
)
)
(copyfiles
(help @copyfiles-help)
(source "Icons")
(dest (tackon DestDir "Icons"))
(all)
)
;============ Docks ===========
(if (NOT (exists (tackon DestDir "Docks") (noreq)))
(makedir
(tackon DestDir "Docks")
(infos)
)
)
(copyfiles
(help @copyfiles-help)
(source "Docks")
(dest (tackon DestDir "Docks"))
(all)
)
;============ Menus ===========
(if (NOT (exists (tackon DestDir "BrowserII.menu") (noreq)))
(if (exists "S:BrowserII.menu" (noreq))
(
(copyfiles
(help @copyfiles-help)
(source "S:BrowserII.menu")
(dest DestDir)
)
(message (#MenuMoved DestDir))
)
(
(copyfiles
(help @copyfiles-help)
(source "BrowserII.menu")
(dest DestDir)
(newname "BrowserII.menu")
)
))
)
; Always copy the given menu as example as it is referenced in the guide.
(copyfiles
(help @copyfiles-help)
(source "BrowserII.menu")
(dest DestDir)
(newname "BrowserII.menu-example")
)
;========= Commands ===========
(if (bitand WhichCommands 1)
(copyfiles
(help @copyfiles-help)
(source "C/AddIcon")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 2)
(copyfiles
(help @copyfiles-help)
(source "C/BaseName")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 3)
(copyfiles
(help @copyfiles-help)
(source "C/BD")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 4)
(copyfiles
(help @copyfiles-help)
(source "C/For")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 5)
(copyfiles
(help @copyfiles-help)
(source "C/MakeLink")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 6)
(copyfiles
(help @copyfiles-help)
(source "C/TackOn")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 7)
(copyfiles
(help @copyfiles-help)
(source "C/VolName")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 8)
(copyfiles
(help @copyfiles-help)
(source "C/WBInfo")
(dest CommandsDir)
)
)
(if (bitand WhichCommands 9)
(copyfiles
(help @copyfiles-help)
(source "C/WBRun")
(dest CommandsDir)
)
)
;========= ARexx ===========
(if (bitand WhichARexx 1)
(copyfiles
(help @copyfiles-help)
(source "Rexx/DeliPlay.rexx")
(dest ARexxDir)
)
)
(if (bitand WhichARexx 2)
(copyfiles
(help @copyfiles-help)
(source "Rexx/View.adpro")
(dest ARexxDir)
)
)
;========= Scripts ===========
(if (bitand WhichScript 1)
(copyfiles
(help @copyfiles-help)
(source "S/AssignVol")
(dest ScriptDir)
)
)
(if (bitand WhichScript 2)
(copyfiles
(help @copyfiles-help)
(source "S/Extract")
(dest ScriptDir)
)
)
(if (bitand WhichScript 3)
(copyfiles
(help @copyfiles-help)
(source "S/LhArcDir")
(dest ScriptDir)
)
)
(if (bitand WhichScript 4)
(copyfiles
(help @copyfiles-help)
(source "S/LhArcVol")
(dest ScriptDir)
)
)
(if (bitand WhichScript 5)
(copyfiles
(help @copyfiles-help)
(source "S/PPDocToCed")
(dest ScriptDir)
)
)
(complete 100)
(exit)